#ifndef PEUPLE_H_INCLUDED
#define PEUPLE_H_INCLUDED

#include "Mobile.h"

const int _vision1[6][2] = {{0,-2},{1,-1},{1,1},{0,2},{-1,1},{-1,-1}};
const int _vision2[12][2] = {{0,-4},{1,-3},{2,-2},{2,0},{2,2},{1,3},{0,4},{-1,3},{-2,2},{-2,0},{-2,-2},{-1,-3}};
const int _vision3[18][2] = {{0,-6},{1,-5},{2,-4},{3,-3},{3,-1},{3,1},{3,3},{2,4},{1,5},{0,6},{-1,5},{-2,4},{-3,3},{-3,1},{-3,-1},{-3,-3},{-2,-4},{-1,-5}};

class Peuple : virtual public Mobile {
    protected:
        /////////////// ATTRIBUTS ///////////////

        unsigned pv;
        unsigned age;
        unsigned esperance;
        unsigned vision;
        unsigned famine;

    public:
        /////////////// OBJET ///////////////

        Peuple(const string &, const Position &, unsigned int, Monde *, unsigned, unsigned, unsigned, unsigned);
        ~Peuple();

        static int qteRes;
        static unsigned nbInstances;

        /////////////// ACTIONS ///////////////

        void action();
        bool controleAction();
        int determinerPositionVision1(Element *);
        int determinerPositionVision2(Element *);
        int determinerPositionVision3(Element *);
        virtual void seReproduire();
        virtual Element * vision1();
        virtual Element * vision2();
        virtual Element * vision3();
        virtual void collecte(Element *);
        virtual bool consommer();
        virtual void vieillir();
};

#endif // PEUPLE_H_INCLUDED
